﻿Public Class GrupoOperador

    Public Shared ReadOnly Property ID() As String
        Get
            If System.Web.HttpContext.Current.Session("GrupoOperadorID") Is Nothing Then
                Try
                    Using sCon As New System.Data.OleDb.OleDbConnection(Env.ConnectionString)
                        Using sCom As New System.Data.OleDb.OleDbCommand(String.Format("SELECT cd_grupo_operadores FROM dbo.wld_miembros_grupo where cd_operador = '{0}'", Common.Env.Operador), sCon)
                            sCon.Open()
                            Using reader As System.Data.OleDb.OleDbDataReader = sCom.ExecuteReader()
                                While reader.Read()
                                    System.Web.HttpContext.Current.Session("GrupoOperadorID") = reader.GetValue(0).ToString()
                                End While
                            End Using
                        End Using
                    End Using
                Catch
                End Try
            End If
            Return System.Web.HttpContext.Current.Session("GrupoOperadorID")
        End Get
    End Property
End Class
